import requests

from test.api.login import get_verity_code, login
from test.tools.check import check

test_data=[
    ("admin","HM_2023_test","2",200,200,"成功"),
    ("admin","123456","2",200,500,"错误"),
    ("admin","HM_2023_test","3",200,500,"失效")
]

for i in test_data:
   uuid= get_verity_code().json().get("uuid")
   response = login(i[0],i[1],uuid,i[2])
   check(response,i[3],i[4],i[5])